class GistsComments
  attr_accessor :github

  def initialize(github)
    @github = github
  end

  def listGistComments(id)
    @github.get('gists/%s/comments' % id)
  end

  def getGistComment(id)
    @github.get('gists/comments/%s' % id)
  end

  def createGistComment(id, body)
    params = {
        :body => body
    }
    data = params.to_json
    @github.post('gists/%s/comments' % id, data)
  end

  def editGistComment(id, body)
    params = {
        :body => body
    }
    data = params.to_json
    @github.patch('gists/comments/%s' % id, data)
  end

  def deleteGistComment(id)
    @github.delete('gists/comments/%s' % id)
  end
end
